package exercise;

import java.util.HashMap;
import java.util.Map;
import java.util.WeakHashMap;

/**
 * @author Yancy
 * @program springioctest
 * @create 2020-11-20
 */
public class Demo01 {

  public static void main(String[] args) {
    int y = 1999;
    boolean result = (y % 4 == 0 && y % 100 !=0) || y % 400 ==0;
    if(result){
        System.out.println(y + "是闰年");
    }

    String s2;
    StringBuffer s;
    HashMap hashMap = new HashMap();
    hashMap.put("01","nihao");
    Map map = new HashMap();
    WeakHashMap weakHashMap = new WeakHashMap();

  }

  //实现冒泡排序
  public static void bubbleSort(int[] arr){
    for (int i = 0; i < arr.length; i++) {
      for (int j = 0; j < arr.length-1-i; j++) {
        if(arr[j] > arr[j+1]) {
          int temp = arr[j];
          arr[j] = arr[j + 1];
        }
      }
    }
  }
}
